<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2019/8/6
  Time: 15:27
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" pageEncoding="UTF-8" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <title>insert title here</title>
    <% String path=request.getContextPath(); %>
    <meta content="text/html">
    <script type="application/javascript" charset="UTF-8" src="<%=path%>/static/js/jquery-3.4.1.min.js"/>
</head>
<body>
    <button onclick="">抢红包测试</button>
    <script type="application/javascript">
        function text(username) {
            console.log("usernum:"+username);
            for (var i = 0; i <username ; i++) {
                console.log("i:"+i);
                $.post('<%=path%>/red-pack/grab',{"userid":i},function (data) {
                    console.log(data)
                })
            }
        }
    </script>
</body>
</html>
